package com.tchy.cloud.entity;

import javax.persistence.*;
import javax.persistence.criteria.CriteriaBuilder;
import java.math.BigDecimal;
import java.util.Date;

import static javax.persistence.GenerationType.IDENTITY;

/**
 * Created by xiaoji on 2017/2/20.
 */
@Entity
@Table(name = "a_customer_capital", schema = "", catalog = "")
public class ACustomerCapitalEntity {
    private Long capitalId;
    private Integer type;
    private ACustomerEntity aCustomerEntity;
    private Long orderId;
    private Long regardId;
    private Integer opt2;
    private BigDecimal money;
    private Date tradingTime;
    private String tradingDesc;

    @Id
    @GeneratedValue(strategy = IDENTITY)
    @Column(name = "capital_id")
    public Long getCapitalId() {
        return capitalId;
    }

    public void setCapitalId(Long capitalId) {
        this.capitalId = capitalId;
    }

    @Basic
    @Column(name = "type")
    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    @ManyToOne(fetch = FetchType.LAZY)
    @JoinColumn(name = "customer_id")
    public ACustomerEntity getaCustomerEntity() {
        return aCustomerEntity;
    }

    public void setaCustomerEntity(ACustomerEntity aCustomerEntity) {
        this.aCustomerEntity = aCustomerEntity;
    }

    @Basic
    @Column(name = "order_id")
    public Long getOrderId() {
        return orderId;
    }

    public void setOrderId(Long orderId) {
        this.orderId = orderId;
    }

    @Basic
    @Column(name = "regard_id")
    public Long getRegardId() {
        return regardId;
    }

    public void setRegardId(Long regardId) {
        this.regardId = regardId;
    }

    @Basic
    @Column(name = "opt")
    public Integer getOpt2() {
        return opt2;
    }

    public void setOpt2(Integer opt) {
        this.opt2 = opt;
    }

    @Basic
    @Column(name = "money")
    public BigDecimal getMoney() {
        return money;
    }

    public void setMoney(BigDecimal money) {
        this.money = money;
    }

    @Basic
    @Column(name = "trading_time")
    public Date getTradingTime() {
        return tradingTime;
    }

    public void setTradingTime(Date tradingTime) {
        this.tradingTime = tradingTime;
    }

    @Basic
    @Column(name = "trading_desc")
    public String getTradingDesc() {
        return tradingDesc;
    }

    public void setTradingDesc(String tradingDesc) {
        this.tradingDesc = tradingDesc;
    }

}
